package com.syh.core.ddd.event;

import com.syh.core.ddd.domain.DomainEvent;
import com.syh.core.eventBus.EventBus;
import com.syh.core.eventBus.EventHandle;

public interface DomainEventBus extends EventBus {

  /**
   * 订阅
   */
  void subscribe(String eventName, EventHandle eventHandle);

  /**
   * 发布同步事件
   *
   * @param domainEvent
   */
  void publicEvent(DomainEvent domainEvent);


}
